import 'package:freezed_annotation/freezed_annotation.dart';
import 'package:sonora/bloc/base/sj_base_event.dart';
import 'package:sonora/shared/lib/enum/sj_language_code.dart';

part 'sj_app_event.freezed.dart';

abstract class SjAppEvent extends SjBaseEvent {
  const SjAppEvent();
}

@freezed
class SjAppInitEvent extends SjAppEvent with _$SjAppInitEvent {
  const factory SjAppInitEvent() = _SjAppInitEvent;
}

@freezed
class SjIsLoginStatusChanged extends SjAppEvent with _$SjIsLoginStatusChanged {
  const factory SjIsLoginStatusChanged({
    required bool isLogin
  }) = _SjIsLoginStatusChanged;
}

@freezed
class SjAppThemeChanged extends SjAppEvent with _$SjAppThemeChanged {
  const factory SjAppThemeChanged({
    required bool isDarkTheme
  }) = _SjAppThemeChanged;
}

@freezed
class SjAppLanguageChanged extends SjAppEvent with _$SjAppLanguageChanged {
  const factory SjAppLanguageChanged({
    required SjLanguageCode languageCode
  }) = _SjAppLanguageChanged;
}
